package com.lq.demo.demo.mode.mycache;

import java.util.Map;
import java.util.Set;

/**
 * 缓存接口
 */
public interface ICacheManager {

    void putCache(String key, EntitiCache entitiCache);

    void putCache(String key, Object data);

    void putCache(Number key, EntitiCache entitiCache);

    void putCache(Number key, Object data);

    void putCache(Object key, EntitiCache entitiCache);

    <T>void putCache(T key, Object data);

    EntitiCache getCacheByKey(String key);

    EntitiCache getCacheByKey(Number key);

    EntitiCache getCacheByKey(Object key);

    Object getCacheDataByKey(String key);

    Object getCacheDataByKey(Number key);

    Object getCacheDataByKey(Object key);

    void clearAll();

    void clearByKey(String key);

    void clearByKey(Number key);

    void clearByKey(Object key);

    Map<Object, EntitiCache> getAllCache();

    Set     getAllKeys();

    boolean isContains(String key);

    boolean isContains(Number key);

    boolean isContains(Object key);

    boolean isTimeOut(String key);

    boolean isTimeOut(Number key);

    boolean isTimeOut(Object key);


    Integer getSize();
}
